package com.xinxing.learning.security.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xinxing.learning.security.entity.Role;
import com.xinxing.learning.security.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserMapper extends BaseMapper<User> {

    User loadUserByUsername(@Param("username") String username);

    List<Role> getRolesByUid(@Param("uid") Integer uid);

    Integer updatePassword(@Param("username") String username, @Param("password") String password);
}
